#include "deviceconnect.h"

Deviceconnect::Deviceconnect(): leftDevice(NULL), rightDevice(NULL)
{
    this->status = 0;
    this->olt = 0;
    valid = false;
    p1 = NULL;
    p2 = NULL;
}
void Deviceconnect::setCid(int cid)
{
    this->cid = cid;
}

void Deviceconnect::setLeftDeviceId(int leftDeviceId)
{
    this->leftDeviceId = leftDeviceId;
}

void Deviceconnect::setleftPort(int leftPort)
{
    this->leftPort = leftPort;
}

void Deviceconnect::setRightDeviceId(int rightDeviceId)
{
    this->rightDeviceId = rightDeviceId;
}

void Deviceconnect::setRightPort(int rightPort)
{
    this->rightPort = rightPort;
}

void Deviceconnect::setSpeed(float speed)
{
    this->speed = speed;
}

void Deviceconnect::setStatus(int status)
{
    this->status = status;
}

void Deviceconnect::setCdate(QDateTime  cdate)
{
    this->cdate = cdate;
}

void Deviceconnect::setUdate(QDateTime  udate)
{
    this->udate = udate;
}

int Deviceconnect::getCid()
{
    return this->cid;
}

int Deviceconnect::getLeftDeviceId()
{
    return this->leftDeviceId;
}

int Deviceconnect::getLeftPort()
{
    return this->leftPort;
}

int Deviceconnect::getRightDeviceId()
{
    return this->rightDeviceId;
}

int Deviceconnect::getRightPort()
{
    return this->rightPort;
}

float Deviceconnect::getSpeed()
{
    return this->speed;
}

int Deviceconnect::getStatus()
{
    return this->status;
}

QDateTime Deviceconnect::getCdate()
{
    return this->cdate;
}

QDateTime  Deviceconnect::getUdate()
{
    return this->udate;
}
void Deviceconnect::setLeftDevice(Device *leftDevice)
{
    this->leftDevice = leftDevice;
}

void Deviceconnect::setRightDevice(Device *rightDevice)
{
    this->rightDevice = rightDevice;
}

Device *Deviceconnect::getLeftDevice()
{
    return this->leftDevice;
}

Device *Deviceconnect::getRightDevice()
{
    return this->rightDevice;
}

void Deviceconnect::setSubsetIp(QString subsetIp)
{
    this->subsetIp = subsetIp;
}
void Deviceconnect::setSubsetMask(QString subsetMask)
{
    this->subsetMask = subsetMask;
}
QString Deviceconnect::getSubsetIp()
{
    return this->subsetIp;
}
QString Deviceconnect::getSubsetMask()
{
    return this->subsetMask;
}
void Deviceconnect::setConnectType(int connectType)
{
    this->connectType = connectType;
}
int Deviceconnect::getConnectType()
{
    return this->connectType;
}
void Deviceconnect::setOlt(int olt)
{
    this->olt = olt;
}
int Deviceconnect::getOlt()
{
    return this->olt;
}
bool Deviceconnect::isValid()
{
    return this->valid;
}

void Deviceconnect::setValid(bool isValid)
{
    this->valid = isValid;
}
void Deviceconnect::setSecondFlag(int secondFlag)
{
    this->secondFlag = secondFlag;
}

int Deviceconnect::getSecondFlag()
{
    return this->secondFlag;
}
